package com.huluobo.document

import com.huluobo.document.entity.DocEntity
import com.huluobo.lib_base.Res
import kotlinx.coroutines.flow.Flow
import okhttp3.MultipartBody
import retrofit2.http.GET
import retrofit2.http.Multipart
import retrofit2.http.POST
import retrofit2.http.Part
import retrofit2.http.Query

/**
 *  Created by LC on 2025/2/6.
 */
interface ApiService {
    @GET("/api/resource/all")
    fun getDoc(): Flow<Res<DocEntity>>

    @GET("/api/resource/delete")
    fun deleteDoc(@Query("id") id: Int): Flow<Res<String?>>

    @Multipart
    @POST("/api/file/uploadimg")
    fun uploadDoc(@Part data: List<MultipartBody.Part>): Flow<Res<String>>
}